package com.iplatform.file.function.resourcedata.entity;

import com.iplatform.module.annotation.KeyId;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;

/**
 * @className: FIleBean
 * @description: TODO 类描述
 * @author: chensk
 * @date: 2020/12/3
 **/
@Data
@AllArgsConstructor
@NoArgsConstructor
public class FileBean {
    @KeyId
    @ApiModelProperty(value = "主键Id")
    private Long id;
    @ApiModelProperty(value = "所属目录ID")
    private Long parentId;
    @ApiModelProperty(value = "文件路径")
    private String filePath;
    @ApiModelProperty(value = "文件名称")
    private String fileName;
    @ApiModelProperty(value = "文件创建时间")
    private Date createTime;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }
    
    public Long getParentId() {
        if (parentId == null) return 0l;
        return parentId;
    }

    public void setParentId(Long parentId) {
        this.parentId = parentId;
    }
   

    public String getFilePath() {
        return filePath;
    }

    public void setFilePath(String filePath) {
        this.filePath = filePath;
    }

    public String getFileName() {
        return fileName;
    }

    public void setFileName(String fileName) {
        this.fileName = fileName;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}
